cmake_minimum_required(VERSION 3.0.0)
project(hw2 VERSION 0.1.0)

# 开启编译器优化3
set(CMAKE_BUILD_TYPE Release)
set(CMAKE_C_FLAGS_RELEASE "-O3")

# 编译静态链接
add_library(matrix STATIC matrix.c)

# 编译可执行文件
add_executable(my_matrix_multiply my_matrix_multiply.c)
target_link_libraries(my_matrix_multiply matrix pthread)

add_executable(create_matrix create.c)
target_link_libraries(create_matrix matrix)
